-
Notifications
You must be signed in to change notification settings - Fork 401
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Java LS with vscode-pde rebuilds workspace for every restart #1961
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Snjezana Peco <[email protected]>
The reason is probably from the following code. It will bring some unnecessary project update event if Reproduce steps:
|
Right! |
How would this work on the client side ? Would the client need to set |
It could be done in the Eclipse PDE support extension. |
@testforstephen , can this be used to avoid having vscode-pde rebuilding the workspace unnecessarily ? How would vscode-pde set this property, since it only contributes to JDT-LS via |
Yes, vscode-pde doesn't have a good way to specify such property. We need a better approach that does not depends on system property to fix this. |
Ok, so then we can't merge this PR in the current form. What we really need is a nice way for JDT-LS to detect whether a bundle extension wants to handle setting the runtime, and if so, simply avoid setting it. |
Fixes #1960
Both, VS Code PDE and Java LS set default JVMs.
See
If those JVMs are different, Java LS will update all projects.
The issue can't be reproduced when starting VS Code with JDK 11 and without java.configuration.runtimes.
The PR adds the java.ls.doNotSetDefaultJVM property. Java LS won't set a default JVM if it is started with -Djava.ls.doNotSetDefaultJVM=true.
Test vsix: https://github.com/snjeza/vscode-test/raw/master/java-1.2.4.vsix
Test project: https://github.com/eclipse/eclipse.jdt.ls
Test vmargs:
Signed-off-by: Snjezana Peco [email protected]